@import (reference) "../defs.less";


@img_base: '../../images';
@djblets_img_base: '../../../djblets/images';


/****************************************************************************
 * Review-specific macros
 ****************************************************************************/

/* Keep the label from shifting when the pencil icon is hidden/shown. */
.inline-editor-label() {
  display: block;
  line-height: 16px;
  vertical-align: top;
}

/* Adds a left-facing arrow to the left-hand side of a box. */
.left-arrow-callout(@color) {
  position: relative;

  &:before, &:after {
    position: absolute;
    left: -19px;
    top: 17px;
    right: 100%;
    border: 1px transparent solid;
    content: " ";
    display: block;
    width: 0;
    height: 0;
  }

  &:before {
    border-right-color: @box-border-color;
    border-width: 10px;
  }

  &:after {
    border-width: 9px;
    border-right-color: @color;
    margin-top: 1px;
    margin-left: 2px;
  }
}

/* Changes the color of an existing callout arrow. */
.left-arrow-callout-color(@color) {
  &:after {
    border-right-color: @color;
  }
}

.rich-text-loading() {
  color: transparent;
  background: white url("@{img_base}/spinner.gif") no-repeat @box-padding @box-padding;
}

.review-comments-inline() {
  &.draft {
    dt label a {
      color: #4e9a06;
    }
  }

  dl {
    dt {
      label {
        .inline-editor-label();

        a {
          color: #AB5603;
          font-size: 1.1em;
          font-weight: bold;
          text-decoration: none;
        }

        .gravatar-container {
          background: white;
          .border-radius(50%);
          display: inline-block;
          overflow: hidden;
          width: 32px;
          height: 32px;
        }

        .user-reply-info {
          display: inline-block;
          overflow: hidden;

          time {
            display: block;
          }
        }
      }

      span {
        color: #487858;
        font-weight: normal;
      }
    }
  }
}

/* Sets up an element to appear as a pop-up review request action menu. */
.review-request-action-popup-menu() {
  display: block !important;
  visibility: hidden;
  z-index: @z-index-menu;
  .opacity(0);
  .transition(visibility 0.1s, opacity 0.1s;);
}


/****************************************************************************
 * Actions
 ****************************************************************************/
.actions-container {
  background: @review-request-action-bg;
  border: 1px @review-request-action-border-color solid;
  border-bottom: 0;
  overflow: hidden;
  .border-radius(@box-inner-border-radius @box-inner-border-radius 0 0);
  .box-sizing(border-box);

  /*
   * This adds some content to the actions list, ensuring that even if it's
   * empty, there will be a suitable height.
   */
  .actions:before {
    content: "";
    float: left;
    visibility: hidden;
    padding: 0;
  }
}


.actions {
  .box-sizing(border-box);
  float: right;
  list-style: none;
  margin: 0;
  padding: 0;
  white-space: nowrap;

  &.actions-left {
    float: left;

    #hide-review-request-link {
      padding: 0.6em 0.6em 0.3em 0.6em;
    }
  }

  a {
    color: black;
    cursor: pointer;
    display: block;
    text-decoration: none;
    padding: @review-request-action-padding-horiz
             @review-request-action-padding-vert;
  }

  img {
    vertical-align: middle;
  }

  li {
    float: left;
    margin: 0;
    padding: 0;

    .on-mobile-medium-screen-720({
      /* Give some extra room for tapping. */
      padding: @review-request-action-mobile-padding;
    });

    &:hover {
      background-color: @review-request-action-hover-bg;
    }

    &:active {
      background-color: @review-request-action-active-bg;
    }

    &.has-menu {
      &:hover > ul {
        visibility: visible;
        .opacity(100);
      }

      > .menu {
        .review-request-action-popup-menu();

        .on-mobile-medium-screen-720({
          margin-left: -@review-request-action-mobile-padding;
          margin-top: @review-request-action-mobile-padding;
        });
      }
    }

    &.action-view-diff {
      background: #FFFFEE;
      font-size: 105%;

      a {
        padding-left: 1.5em;
        padding-right: 1.5em;
      }
    }
  }

  .menu {
    background: @review-request-action-menu-bg;
    border: 1px @review-request-action-menu-border-color solid;
    float: none;
    list-style: none;
    margin: 0;
    padding: 0;
    position: absolute;
    z-index: @z-index-menu;
    .border-radius(0 0 @box-border-radius @box-border-radius);
    .box-shadow(@box-shadow);

    li {
      background: @review-request-action-bg;
      border: 0;
      float: none;
      margin: 0;
      padding: 0;

      .on-mobile-medium-screen-720({
        /* Give some extra room for tapping. */
        padding: @review-request-action-mobile-padding;
      });

      &:last-child {
        .border-radius(0 0 @box-border-radius @box-border-radius);
      }

      &:hover {
        background-color: @review-request-action-menu-item-hover-bg;
      }

      a {
        color: black;
        border: 0;
        display: block;
        margin: 0;
        padding: 8px 10px;
        text-decoration: none;
      }
    }
  }
}

.actions-right-container {
  > li {
    &:hover {
      /* Don't let the action bar's background change by default. */
      background: inherit;

      .on-mobile-medium-screen-720({
        background: @review-request-action-hover-bg;
      });
    }

    & > .actions-right {
      .on-mobile-medium-screen-720({
        /* Mimic the styling of a standard menu, on mobile only. */
        .actions > .menu();
        .review-request-action-popup-menu();

        background: @review-request-action-bg;
        display: none;
        margin-left: 0;
        position: absolute;
        left: 0;
        width: 100%;
        white-space: normal;
      });

      > li {
        .on-mobile-medium-screen-720({
          background: transparent;
          .border-radius(0);
          display: inline-block;
          padding: @review-request-action-mobile-padding;
          text-align: left;
        });

        &:last-child {
          .border-radius(0 @box-inner-border-radius 0 0);

          .on-mobile-medium-screen-720({
            .border-radius(0);
          });
        }
      }
    }
  }

  .mobile-actions-menu-label {
    display: none;

    .on-mobile-medium-screen-720({
      display: inline-block;
    });
  }
}

.actions.page-tabs {
  background: @review-request-action-bg;
  border: 1px @review-request-border-color solid;
  border-bottom-width: 0;
  .border-radius(@box-border-radius @box-border-radius 0 0);
  margin-left: 1.5em;
  overflow: hidden;

  .review-ui-box & {
    .active {
      background: @review-ui-header-bg;
    }
  }

  li {
    border-bottom: 1px @review-request-action-border-color solid;
    min-width: 6em;
    text-align: center;

    &.active {
      background: @review-request-bg-gradient-start;
      border: 1px @review-request-border-color solid;
      border-bottom-color: transparent;
      border-top: 0;

      &:first-child {
        border-left: 0;
      }

      &:last-child {
        border-right: 0;
      }
    }
  }
}

.review-request-header {
  border-bottom: 1px @review-request-action-border-color solid;

  .on-mobile-medium-screen-720({
    text-align: center;
  });
}


/****************************************************************************
 * Code Mirror
 ****************************************************************************/
.CodeMirror {
  border: @textarea-border;
  height: auto;
  margin: @textarea-editor-margin;

  .CodeMirror-lines {
    padding: @textarea-editor-padding;
  }

  .CodeMirror-scroll {
    overflow-y: hidden;
    overflow-x: auto;
  }

  pre {
    padding: 0;
  }

  .cm-header {
    color: black;
  }

  .cm-comment {
    color: #4444cc;
  }

  .cm-variable-2 {
    color: black;
  }
}


/****************************************************************************
 * Review Request Box
 ****************************************************************************/
.markdown-info {
  color: blue;
  font-size: 8pt;
  font-weight: normal;
  float: right;
  line-height: 25px;
  margin-right: 0.5em;
  text-decoration: none;

  .on-mobile-medium-screen-720({
    /* Let the Markdown Reference link flow to the next line. */
    display: block !important;
    float: none;
    margin-top: 0.5em;
  });

  &:hover {
    text-decoration: underline;
  }
}

.review-request {
  /*
   * Any changes to this need to be reflected in _resizeLayout in
   * reviewRequestEditorView.js
   */
  @details-width: 300px;

  background: none;
  border: 0;

  label {
    color: @review-request-label-color;
    font-weight: bold;
  }

  noscript form {
    margin: 10px 5px 5px 5px;
    text-align: right;
  }

  textarea {
    border: @textarea-border;
    height: 1.5em;
    overflow: hidden;
  }

  .box-inner {
    background-image: none;
  }

  .content {
    padding: @box-padding;
    position: relative;

    &.sliding {
      margin-top: -5px;
    }

    img {
      border: none;
    }

    .editable.loading {
      .rich-text-loading();
    }

    .field-container {
      position: relative;

      &>pre {
        .pre-wrap;
        background-color: #FFFFFF;
        border: @textarea-border;
        margin: @textarea-editor-margin;
        padding: @textarea-editor-padding;
      }
    }
  }

  .content-divider {
    border-top: 1px #C2C1B0 solid;
  }

  .inline-editor-form {
    &.summary-editor {
      margin-top: -2px;
      margin-left: -3px;
    }

    input[type='text']:not(:focus) {
      .box-shadow(0px 0px 4px rgba(255, 0, 0, .75));
    }
  }

  .main {
    background-color: @review-request-bg;
    #gradient > .vertical(@review-request-bg-gradient-start,
                          @review-request-bg-gradient-end);
    border: 1px @review-request-border-color solid;
    border-top: 0;
    .border-radius(0 0 @box-border-radius @box-border-radius);
    clear: both;
    padding: 0.5em;
  }

  #required-field-legend {
    color: darkRed;
    font-weight: bold;
    padding: @box-padding;
  }

  .header {
    padding: @box-padding;
  }

  .star {
    float: left;
    margin-right: 10px;
  }

  #review_request_details {
    border-spacing: 0px;
    float: right;
    width: @details-width;
    padding: @box-padding;

    .on-mobile-medium-screen-720({
      /* Give the details pane its own full row above the textareas. */
      float: none;
      width: auto;
    });

    a {
      color: @review-request-link-color;
      text-decoration: none;
    }

    th {
      color: #39350b;
      font-weight: bold;
      text-align: left;
      white-space: nowrap;
    }

    tbody {
      td, th {
        padding: 0;
        vertical-align: top;
      }

      th, td .field {
        padding-top: 3px;
      }

      td {
        padding-left: 1em;

        span {
          display: inline-block;
          margin-right: 4px;
          word-wrap: break-word;
        }

        .editicon {
          margin-left: 0;
        }
      }

      th {
        padding-bottom: 1.5em;
        padding-left: 1em;
        text-align: right;
        white-space: nowrap;
      }
    }

    thead {
      &.first-fieldset th {
        padding-top: 0;
      }

      th {
        color: @review-request-label-color;
        font-size: 120%;
        padding: 2em 0 1em 0;
      }
    }

    #target_people .inactive {
      text-decoration: line-through;
    }

    .buttons {
      display: block;
      margin-bottom: 1em;
      padding: 6px 0 0 0;

      input {
        font-size: 11px;
      }
    }
  }

  #review_request_extra {
    .box-sizing(border-box);
    clear: both;
    margin-top: 1em;

    h3 {
      color: @review-request-label-color;
      font-size: 120%;
      margin: 0;
      padding: 0;
    }

    label.textarea-label {
      display: block;
      min-height: 16px;

      img {
        vertical-align: middle;
      }
    }
  }

  #review_request_main {
    margin-right: (@details-width + 10px);
    position: relative;

    .on-mobile-medium-screen-720({
      margin-right: 0;
    });

    label {
      font-size: 120%;
    }
  }

  #review-request-warning {
    background-color: @review-request-warning-bg;
    border: 1px solid @review-request-warning-border-color;
    display: none;
    font-weight: bold;
    padding: 5px;
    text-align: center;
  }

  #diff_revision {
    font-weight: bold;
    text-align: right;
    vertical-align: bottom;
  }

  #status {
    color: #39350b;
    margin: 5px 0;
  }

  #summary_wrapper {
    @line-height: 2.6em;

    line-height: @line-height;
    padding: 0;

    .on-mobile-medium-screen-720({
      margin-bottom: 1em;
    });

    label, #field_summary {
      font-size: 14px;
    }

    label {
      margin-right: 0.5em;

      .on-mobile-medium-screen-720({
        /* Hide the Summary label on mobile. */
        display: none;
      });
    }

    .rb-icon-edit {
      vertical-align: text-bottom;
    }

    #field_summary {
      display: inline;

      .on-mobile-medium-screen-720({
        font-size: 120%;
      });

      a {
        color: black;
        text-decoration: none;
      }
    }
  }

  .actions-container {
    .star {
      margin: 5px;
    }
  }

  #updated_time, #created_time {
    text-align: right;
    vertical-align: bottom;
  }

  .editicon {
    text-decoration: none;
  }

  .required-flag {
    color: @required-flag-color;
    font-size: 10px;
    font-weight: bold;
    padding: 0 2px;
  }
}

#review_request_form {
  input[type='text'], textarea {
    width: 400px;
  }
}


/****************************************************************************
 * Review UIs
 ****************************************************************************/
.review-ui-box {
  &.has-review-ui-box-content .actions-container {
    .border-radius(@box-inner-border-radius @box-inner-border-radius 0 0);

    .actions > li:last-child {
      .border-radius(0 @box-inner-border-radius 0 0);
    }
  }

  .actions-container {
    .border-radius(@box-inner-border-radius);

    .actions > li:last-child {
      .border-radius(0 @box-inner-border-radius @box-inner-border-radius 0);
    }
  }

  .review-ui-box-content {
    border: 1px @review-request-border-color solid;
    border-top: 0;
    clear: both;
    padding: 0;
    min-height: 5em;
  }

  .review-ui-header {
    border-bottom: 1px @diff-file-border-color solid;
    background: @review-ui-header-bg;
    min-height: 2em;

    h1 {
      margin: 0;
      padding: 8px;
      font-size: 10pt;
    }
  }
}


/****************************************************************************
 * Reviews
 ****************************************************************************/

#reviews {
  margin-left: @reviews-padding-horiz;
  margin-right: @reviews-padding-horiz;

  .on-mobile-medium-screen-720({
    margin: 0;
  });

  .box {
    margin: 2em 0;
    .left-arrow-callout(white);

    .on-mobile-medium-screen-720({
      margin-top: 1em;
    });
  }

  .box-container {
    padding-left: 75px;
    width: auto;

    .on-mobile-medium-screen-720({
      padding-left: 0;
    });
  }

  .box-statuses {
    float: left;
    text-align: center;

    .on-mobile-medium-screen-720({
      margin-top: 3em;
      float: none;
    });

    .box-status {
      position: relative;
      .transition(0.2s linear all);

      &.has-issues {
        .gravatar-container {
          border-color: darken(@issue-opened-bg, 45%);
        }
      }

      &.ship-it {
        .gravatar-container {
          border-color: #6ebf20;
        }

        .fix-it-label {
          -webkit-transition-delay: 0.2s;
          transition-delay: 0.2s;
        }
      }

      &.ship-it.has-issues {
        .gravatar-container {
          border-color: darken(@issue-opened-bg, 45%);
        }

        .fix-it-label {
          z-index: 1;
        }

        .ship-it-label {
          position: absolute;
          top: 3px;
          margin-left: 2px;
          padding-left: 2px;
          padding-right: 2px;
        }
      }

      .gravatar-container {
        background: white;
        border: 2px #CCC dotted;
        .border-radius(50%);
        overflow: hidden;
        width: 48px;
        height: 48px;
        margin: 0 5px;
        .transition(border-color 0.4s ease-in-out);

        .on-mobile-medium-screen-720({
          display: inline-block;
          vertical-align: top;
        });

        img {
          border: 2px white solid;
          .border-radius(50%);
          .box-sizing(border-box);
        }
      }

      .labels-container {
        margin-top: -5px;
        position: relative;

        .on-mobile-medium-screen-720({
          display: inline-block;
          margin-top: 0;
          top: 4px;
        });
      }

      label {
        border: 1px #888888 solid;
        .border-radius(@box-border-radius);
        display: block;
        line-height: 1.5;
        margin-bottom: @page-container-padding;
        padding: 2px 4px;
        position: absolute;
        left: 0;
        top: 0;
        width: 4.5em;

        .on-mobile-medium-screen-720({
          margin-bottom: 0;
        });

        &.ship-it-label {
          border: 1px darken(#aeff60, 40%) solid;
          background: #aeff60;

          /*
           * NOTE: The ';' at the end here is intentional. It forces Less to
           *       preserve the commas, rather than assuming they're separating
           *       arguments to the mixin.
           */
          .transition(padding 0.2s ease-in-out,
                      top 0.2s ease-in-out,
                      margin 0.2s ease-in-out
                      ;);
        }

        &.fix-it-label {
          border: 1px darken(@issue-opened-bg, 50%) solid;
          background: @issue-opened-bg;

          .transition(left 0.5s ease-in-out,
                      opacity 0.8s ease
                      ;);
        }
      }
    }
  }

  > .changedesc,
  > .review {
    clear: both;
  }
}

#reviews .box {
  border: 0;

  .on-mobile-medium-screen-720({
    &:after, &:before {
      content: none
    }
  });

  &.collapsed {
    .left-arrow-callout-color(#ECECEE);

    .body {
      display: none;
    }

    .box-inner {
      background: #ECECEE;
    }

    .banner {
      border-bottom: 0;
      margin-bottom: 0;
    }
  }

  .box-inner {
    background: none;
    min-height: 5em;
    overflow: hidden;
  }

  .collapse-button {
    border: 1px #333333 solid;
    cursor: pointer;
    float: left;
    margin-right: 0.5em;
    margin-top: -1px;
    padding: 0;
  }
}

#reviews .review {
  &.has-draft {
    .box {
      .left-arrow-callout-color(@draft-bg-color);
    }

    .header {
      background: @draft-bg-color;
    }
  }

  .banners {
    .banner {
      border-left: 0;
      border-right: 0;
      border-top: 0;
      .box-sizing(border-box);

      &.floating {
        border-top: 0;
        margin-top: 0;
      }
    }
  }

  .body {
    clear: both;

    pre {
      margin-bottom: 0;
      .pre-wrap;
    }

    .comment-text:target {
      background-color: #E7EDF3;
      border: 1px solid @dark-blue;
      padding: 1em;
    }

    .body_top, .body_bottom {
      margin: 2em;
    }
  }

  .body-top-comment-section,
  .body-bottom-comment-section,
  .comments > dd,
  .review-comments > dd {
    margin: 0 2em 4em 2em;

    &:last-child {
      margin-bottom: 2em;
    }
  }

  .box {
    background: white;
    border: 0;

    .box-main {
      padding: 0;
    }
  }

  .box-inner {
    background: white;
    border: 1px @review-box-border-color solid;
  }

  .controls {
    list-style: none;
    margin: 0;
    padding: 0;
    text-align: left;

    a {
      color: black;
      display: inline-block;
      text-decoration: none;
      background: #ECECEC;
      border: 1px #C3C3C3 solid;
      margin-top: 1em;
      padding: 0.6em 1em;
      .border-radius(@box-border-radius);

      &:hover {
        background: #F3F3F3;
      }

      .fa {
        margin-right: 5px;
      }
    }

    li {
      display: inline;
    }
  }

  .comments, .review-comments {
    border: 0;
    margin: 0;
    padding: 0;

    /*
     * Cover up the left and right borders we add for <dt> to get a clean
     * rounded border. We don't want them sticking out of the box.
     */
    overflow: hidden;

    & > dd {
      margin-top: 2em;
    }

    & > dt {
      thead th {
        font-weight: normal;
      }
    }

    .comment_container {
      border-top: 1px #C0C0C0 solid;
      border-bottom: 1px #C0C0C0 solid;
    }

    .filename a {
      color: black;
      font-weight: bold;
    }

    .file-attachment {
      background: #F0F0F0;
      border-bottom: 1px #C0C0C0 solid;
      padding: 5px;

      .file-attachment-comment-header {
        font-size: 120%;
        white-space: nowrap;

        a {
          text-decoration: none;
        }

        img {
          padding-right: 10px;
          vertical-align: middle;
        }

        .caption {
          color: black;
          margin: 5px 0 0 32px;
        }

        .filename {
          color: black;
          font-weight: bold;
          margin: 0;
          vertical-align: middle;
        }
      }

      .thumbnail {
        margin-top: 0.5em;
      }
    }

    .screenshot {
      background: #F0F0F0;
      border: 1px #C0C0C0 solid;
      font-size: 120%;

      img {
        padding: 5px;
      }

      .filename {
        display: block;
        margin: 0;
        padding: 5px 10px;
      }
    }

    .sidebyside {
      th {
        /*
         * The line numbers aren't clickable in the comment fragments in
         * reviews, so show a standard cursor instead of a pointer cursor.
         */
        cursor: initial;
      }

      .filename-row th {
        background: #F0F0F0;
      }
    }
  }

  .diff-error tbody {
    border: 1px @diff-error-border-color solid;
  }

  .reply-comments {
    margin: 3em 0 2em 0;
    padding: 0;

    &>li {
      display: inline;

      .review-comments-inline();

      dl {
        /*
         * Set a border-bottom to prevent a bug in IE where, without a
         * border-bottom, the content of the dl will shift left by the
         * border-left size for every following item.
         */
        border-bottom: 1px transparent solid;
        margin: 4em 0 2em 0;
        padding: 0;

        dd {
          margin-left: 0;
        }
      }
    }
  }
}

#view_controls {
  list-style: none;
  margin: 1em -(@page-container-padding + @reviews-padding-horiz);
  padding: 1em;
  text-align: center;

  a {
    background: #E0E0E0;
    border: 1px #C3C3C3 solid;
    .border-radius(@box-border-radius);
    color: black;
    display: inline-block;
    padding: 0.6em 1em;
    text-decoration: none;

    &:hover {
      background: #ECECEC;
    }
  }

  li {
    display: inline-block;
    margin: 1em;
    padding: 0;
  }

  .rb-icon {
    vertical-align: top;
  }
}

.sidebyside.loading {
  /* Helps us better keep the size, as long as the comment is within a chunk. */
  padding: 2px 2px 1px 2px;
  width: 100%;

  tbody {
    background-color: #F3F3F3;

    td {
      padding: 4px;
      font-size: 20px;
      text-align: center;
    }
  }
}


/****************************************************************************
 * Change Descriptions
 ****************************************************************************/
#field_changedescription {
  .pre-wrap;
  background-color: @textarea-editor-background;
  border: @textarea-border;
  margin: @textarea-editor-margin;
  padding: @textarea-editor-padding;

  &.loading {
    .rich-text-loading();
  }
}

.changedesc {
  &.box {
    background-color: #fefadf;
    #gradient > .vertical(lighten(@review-request-bg, 5%), @review-request-bg);

    .box-inner {
      border: 1px @review-request-border-color solid;
    }
  }

  .body {
    clear: both;
    padding: @box-padding;

    &>ul {
      list-style: none;
      margin: 1em 0 1em 0;
      padding: 0;

      &>li {
        margin: 3em 0 0 0;

        &:first-child {
          margin-top: 0;
        }
      }
    }

    a {
      color: default;
      text-decoration: none;

      &:hover {
        text-decoration: underline;
      }
    }

    /* Field labels */
    h3 {
      color: @review-request-label-color;
      font-size: 110%;
      margin: 1em 0 0.5em 0;
      padding: 0;

      &.status {
        /* Add some separation between this and the other fields. */
        margin-bottom: 2em;

        &:last-child {
          /*
           * If it's the last child, we don't want that separation, or it'll
           * have an odd amount of extra space.
           */
          margin-bottom: 0.5em;
        }

        .value {
          color: black;
          font-weight: normal;
        }
      }
    }

    /* Used in the textarea field diffs and the Change Summary section. */
    > pre {
      background-color: #FFFFFF;
      border: @textarea-border;
      padding: @textarea-editor-padding;
      font-size: 9pt;
      .pre-wrap;
    }

    /*
     * File attachment/screenshot change lists.
     *
     * These differ from the other field change lists in that they have
     * mini-section labels underneath for each file.
     */
    .caption-changed {
      margin: 2em 0 0 2em;
      padding: 0;

      a {
        /* Treat the link like a field. */
        font-weight: bold;
      }

      td, th {
        vertical-align: top;
      }

      td {
        padding-left: 1em;
      }

      th {
        text-align: right;
      }
    }

    /* Displays changes for field values, with "-" and "+" markers. */
    .changed {
      border: @textarea-border;
      border-collapse: collapse;
      display: inline-block;
      margin: 0;
      padding: 0;
      vertical-align: top;

      a {
        color: blue;
        text-decoration: none;

        &:first-child {
          margin-left: 0;
        }

        &:hover {
          text-decoration: underline;
        }
      }

      td, th {
        font-family: @textarea-font-family;
        padding: 0.3em 0.6em;
      }

      td {
        background: #FEFEFE;
      }

      .new-value .marker {
        background: @diff-insert-linenum-color;
      }

      .old-value .marker {
        background: @diff-delete-linenum-color;
      }
    }

    /* The "Change Summary" section. */
    .changedesc-text {
      margin-bottom: 2em;

      &:last-child {
        margin-bottom: 0;
      }
    }

    /* The diff for text areas. */
    .diffed-text-area {
      background: white;
      border: @textarea-border;
      border-collapse: collapse;
      padding: 0;
      width: 100%;

      a {
        text-decoration: underline;
      }

      pre {
        background: none;
        border: 0;
        margin: 0;
        padding: 0;
        .pre-wrap;
      }

      td {
        font-family: @textarea-font-family;
        padding: 2px 4px;
        vertical-align: top;
        .pre-wrap;
      }

      .delete {
        .line {
          background: @diff-delete-color;
        }

        /* The '-' or '+' marker. */
        .marker {
          color: #990000;
          background: @diff-delete-linenum-color;
        }
      }

      .insert {
        .line {
          background: @diff-insert-color;
        }

        /* The '-' or '+' marker. */
        .marker {
          background: @diff-insert-linenum-color;
        }
      }

      .line {
        width: 100%;

        /*
         * Make sure any images in the Markdown-rendered text are kept
         * small, but with the correct aspect ratio.
         */
        img {
          width: auto;
          max-height: 100px;
        }
      }

      /* The '-' or '+' marker. */
      .marker {
        background: #F9F9F9;
        font-family: @textarea-font-family;
        font-size: @textarea-font-size;
        font-weight: bold;
        text-align: center;
      }

      .replace-new {
        .line {
          background: @diff-insert-color;

          .hl {
            background: desaturate(darken(@diff-insert-color, 15%), 30%);
          }
        }

        /* The '-' or '+' marker. */
        .marker {
          background: @diff-insert-linenum-color;
        }
      }

      .replace-old {
        .line {
          background: @diff-delete-color;

          .hl {
            background: desaturate(darken(@diff-delete-color, 10%), 20%);
          }
        }

        /* The '-' or '+' marker. */
        .marker {
          background: @diff-delete-linenum-color;
        }
      }
    }

    /* Styling for the "Diff" field updates. */
    .diff-changes {
      .line-counts {
        margin-left: 0.5em;

        .delete-count {
          color: @diff-delete-line-count-color;
        }

        .insert-count {
          color: @diff-insert-line-count-color;
        }
      }
    }

    /* Styles for the file listing for the "Diff" field. */
    .diff-index {
      margin-bottom: 0;

      .diff-file-icon {
        min-width: 20px;
        min-height: 20px;
      }

      .diff-file-info {
        /* Compensate for the lack of diff-chunks-cell column. */
        width: 100%;
      }
    }

    .primary-fields {
      h3:first-child {
        margin-top: 2em;
      }
    }

    /*
     * Secondary fields are in more of a Field: Value display, with the
     * fields lining up.
     */
    .secondary-fields {
      width: 100%;

      .on-mobile-medium-screen-720({
        display: block;
      });

      h3 {
        margin: 2px 1em 0 0;
        padding: 0;
        text-align: right;

        .on-mobile-medium-screen-720({
          margin: 0;
          text-align: left;
        });
      }

      &>tbody>tr {
        &>td,
        &>th {
          padding: 0.5em 0;
          vertical-align: top;
          white-space: nowrap;

          .on-mobile-medium-screen-720({
            display: block;
            white-space: normal;
          });
        }

        &>td {
          /*
           * Between this and the white-space: nowrap above, the field labels
           * will end up taking the minimum size without wrapping, and the
           * rest of the width will be given to the value.
           */
          width: 100%;

          &>p {
            /*
             * If the field value is rendered inside a <p>, make sure it
             * aligns with the field label.
             *
             * Note that the label has a larger font than this, so we can't
             * reuse the same pixel value. We have to bump it.
             */
            &:first-child {
              margin-top: 3px;
            }

            /* Don't take up more room than we need in the last <p>. */
            &:last-child {
              margin-bottom: 0;
            }
          }
        }

        &>th {
          .on-mobile-medium-screen-720({
            margin-top: 2em;
          });
        }
      }
    }
  }
}

.box .header {
  .border-radius(@box-border-radius @box-border-radius 0 0);
  padding: 9px;

  a {
    color: black;
    text-decoration: none;
  }

  .header-details {
    overflow: hidden;
  }

  .reviewer {
    float: left;
    font-size: 110%;
    font-weight: bold;
    padding-top: 1px;

    .on-mobile-medium-screen-720({
      float: none;
    });

    a {
      position: relative;
    }
  }

  .posted_time {
    color: #555;
    text-align: right;
    padding-top: 2px;

    .on-mobile-medium-screen-720({
      margin-top: 0.5em;
      text-align: left;
    });
  }

}


/****************************************************************************
 * Updates Bubble
 ****************************************************************************/

#updates-bubble {
  background: #FFF1AB;
  border-top: 1px #888866 solid;
  border-left: 1px #888866 solid;
  bottom: 0;
  .border-radius(10px 0 0 0);
  .box-shadow(-1px -1px 2px rgba(0, 0, 0, 0.15));
  font-size: 110%;
  padding: 1em;
  position: fixed;
  right: 0;

  a, a:visited {
    color: #0000CC;
    text-decoration: none;
  }

  #updates-bubble-buttons {
    margin-left: 2em;
  }
}


/****************************************************************************
 * Review Form
 ****************************************************************************/
#review-form {
  overflow: auto;
  padding: 10px;

  .add-link {
    font-size: 110%;

    &:visited {
      color: @link-color;
    }
  }

  label {
    color: black;
    font-weight: bold;
    margin-top: 10px;
  }

  dt label {
    color: #AB5603;
    font-size: 1.1em;
    font-weight: bold;
    text-decoration: none;
  }

  .comment-text-field > .edit-field {
    margin: 1em 0;

    .comment-text-field {
      label {
        .inline-editor-label();
      }
    }
  }

  #review-form-comments {
    background: none;

    pre {
      .pre-wrap;
    }

    .spinner {
      font-size: 20px;
    }

    .comments {
      list-style: none;
      margin: 0;
      padding: 0;

      > li {
        margin: 2em 0;
        padding: 0;

        .edit-fields {
          margin-left: 2em;
        }

      }
    }

    .review-comments-inline();

    dd {
      margin: 0;
    }
  }
}


/****************************************************************************
 * Uploaded files
 ****************************************************************************/
.file-container {
  float: left;

  .on-mobile-medium-screen-720({
    float: none;
  });

  .file:hover .file-actions {
    visibility: visible;
  }

  .file {
    @file-attachment-bg: white;
    @file-attachment-height: 150px;
    @file-attachment-width: 300px;
    @file-attachment-border-color: #CCCCCC;
    @file-attachment-caption-height: 31px;

    border: 1px @file-attachment-border-color solid;
    display: block;
    position: relative;
    margin: 1em 1.5em 0.5em 0;
    max-width: @file-attachment-width;
    width: @file-attachment-width;
    .box-shadow(@box-shadow);
    .box-sizing(border-box);

    .on-mobile-medium-screen-720({
      margin: 1.5em 0 0 0;
    });

    .fa-spinner {
      font-size: @file-attachment-height / 4;
      line-height: @file-attachment-height;
      vertical-align: middle;
      text-align: center;
    }

    .file-actions {
      .box-sizing(border-box);
      .opacity(95);
      background-color: @dark-grey;
      height: @file-attachment-height - @file-attachment-caption-height - 1px;
      left: 0;
      list-style: none;
      margin: 0;
      padding: 0;
      position: absolute;
      text-shadow: black 0px 0px 4px;
      top: 0;
      visibility: hidden;
      z-index: @z-index-menu;

      li {
        .opacity(100);
        margin: 1em;

        a {
          color: white;
          text-decoration: none;
        }
      }
    }

    .file-thumbnail-container {
      background: @file-attachment-bg;
      height: @file-attachment-height;
      text-align: center;

      a {
        color: black;
        text-decoration: none;
      }

      pre {
        font-size: x-small;
      }

      .thumbnail-properties () {
        max-height: @file-attachment-height;
        max-width: 100%;
        margin: 0;
        padding: 0;
        .box-sizing(border-box);
      }

      .file-thumbnail-overlay {
        .thumbnail-properties();
        position: absolute;
        left: 0;
        width: 100%;
        height: 100%;
        z-index: @z-index-event-overlay;
      }

      .file-thumbnail {
        .thumbnail-properties();
        border: 0;
        overflow: hidden;
        text-align: center;
        white-space: nowrap;
        vertical-align: middle;
        margin: auto;
      }

      .file-thumbnail-clipped {
        border: 0;
        overflow: hidden;
        text-align: left;
        padding: 1em 0 0 1em;
        font-size: 8pt;

        /* Override the styling used for the <pre>s for fields. */
        pre {
          background-color: transparent;
          border: 0;
          margin: 0;
          padding: 0;
        }
      }
    }

    .file-caption-container {
      @file-caption-padding: 30px;

      .box-sizing(border-box);
      .opacity(90);
      background-color: #FEFEFE;
      border-top: 1px #EEEEEE solid;
      bottom: 0;
      line-height: 2.5em;
      padding: 0 @file-caption-padding;
      position: absolute;
      text-align: center;
      z-index: @z-index-subevent-overlay;
      // The 2px here is to make it fit within the border of the parent element
      max-width: @file-attachment-width - 2px;
      width: @file-attachment-width - 2px;

      a {
        color: black;
        text-decoration: none;

        &.empty-caption {
          color: gray;
          font-style: italic;
        }
      }

      .file-caption {
        .ellipsize();
        .opacity(100);
        line-height: @file-attachment-caption-height;
        height: @file-attachment-caption-height;
        text-shadow: 0px 0px 2px white;

        .buttons {
          /*
           * This provides enough padding to cleanly cover much of any file
           * attachment's header below.
           */
          @buttons-padding-vert: 5px;

          position: absolute;
          padding: @buttons-padding-vert 0;

          /* Line up with .file's side borders. */
          margin: 0 0 0 (-1px - @file-caption-padding);

          text-align: center;
          background: darken(@file-attachment-bg, 5%);
          border: 1px @file-attachment-border-color solid;
          border-top: 0;
          display: block;
          width: @file-attachment-width;
          .border-radius(0 0 @box-border-radius @box-border-radius);
          .box-sizing(border-box);
          .box-shadow(@box-shadow);
          z-index: @z-index-deco;
        }
      }

      .inline-editor-form > input[type='text'] {
        background: transparent;
        border: 0;
        font-family: inherit;
        font-size: inherit;
        height: @file-attachment-caption-height;
        margin: 0;
        padding-top: 0;
        padding-bottom: 0;

        /*
         * The 4px is needed to align the input with the text. It matches
         * the margin between the text and pencil.
         */
        padding: 0 @edit-icon-margin 0 0;

        text-align: inherit;
        vertical-align: bottom;
        .box-sizing(border-box);

        &:focus {
          outline: 0;
        }

        /*
         * The box shadow doesn't display correctly in file attachment
         * thumbnails, so hide it. There will be a red background instead.
         */
        &:not(:focus) {
          background: rgba(255, 0, 0, 0.15);
          .box-shadow(none);
        }

        &::-ms-clear {
          display: none;
        }
      }

      .rb-icon-edit {
        vertical-align: middle;
        position: absolute;
        right: 6px;
        bottom: 6px;
      }
    }
  }
}


/****************************************************************************
 * Screenshots
 ****************************************************************************/
.screenshot-caption {
  background-color: #F6F6F6;
  border: 1px #999999 solid;
  border-top: 1px #CCCCCC solid;
  padding: 2px 8px;
  .border-radius(0 0 @box-border-radius @box-border-radius);

  img {
    vertical-align: bottom;
  }
}

.screenshot-container {
  background: white;
  float: left;
  display: inline;
  margin-bottom: 10px;
  margin-right: 10px;
  max-width: 400px;
  min-width: 130px;
  text-align: center;
  vertical-align: middle;
  position: relative;
  .border-radius(@box-border-radius);

  &:hover {
    background-color: #F6F6F6;

    .screenshot-caption {
      background-color: #E6E6E6;
    }
  }

  a {
    color: black;
    text-decoration: none;
  }

  .image {
    border: 1px #999999 solid;
    border-bottom: 0;
    cursor: pointer;
    height: 100px;
    line-height: 100px;
    margin: 0 auto;
    vertical-align: bottom;
    .border-radius(@box-border-radius @box-border-radius 0 0);

    img {
      vertical-align: middle;
      .border-radius(@box-inner-border-radius @box-inner-border-radius 0 0);
    }
  }
}


/****************************************************************************
 * Screenshot Thumbnails
 ****************************************************************************/
#screenshot-thumbnails {
  margin: 2px;
  padding: 0.5em;

  &.dragover {
    border: 2px green dashed;
    display: block;
    margin: 0;
  }
}


/****************************************************************************
 * List of Attached Files
 ****************************************************************************/
#file-list {
  margin: 0;
  padding: 0;

  &.dragover {
    border: 2px green dashed;
    display: block;
    margin: 0;
  }

  h1.drop-indicator {
    clear: both;
    text-align: center;
  }
}


/****************************************************************************
 * Comment detail dialog
 ****************************************************************************/
.comment-dlg {
  border: 1px black solid;
  cursor: default;
  margin-top: 8px;
  position: absolute;

  form {
    background-color: #aceb6f;
    display: block;
    padding: 6px;

    .buttons {
      bottom: 6px;
      left: 6px;
      margin-top: 6px;
      position: absolute;

      input[type="button"] {
        margin-right: 3px;
      }
    }
  }

  h1 {
    background: transparent;
    border: 0;
    margin: 0 0 6px 0;
    padding: 0;
  }

  img.ui-resizable-grip {
    /* Use -1 for bottom and right so it overlaps the resize borders. */
    bottom: -1px;
    cursor: se-resize;
    padding: 0.5em;
    position: absolute;
    right: -1px;
    z-index: @z-index-deco;
  }

  .markdown-info {
    line-height: 16px;
  }

  .status {
    margin: 4px 0;
    font-style: italic;
  }

  .other-comments {
    background-color: #a1c0e3;
    border-right: 1px black solid;
    padding: 6px;

    ul {
      background-color: white;
      border: 1px #333333 solid;
      list-style: none;
      margin: 0;
      overflow: auto;
      padding: 0;
      position: relative;

      li {
        padding: 6px;

        &.even {
          background-color: #F3F3F3;
        }

        h2 {
          font-size: 90%;
          margin: 0 0 6px 0;
          padding: 0;

          .actions {
            font-weight: normal;
            position: absolute;
            right: 6px;

            a {
              background-color: #EEEEEE;
              border: 1px black outset;
              color: black;
              cursor: pointer;
              text-decoration: none;
              margin-left: 6px;
              padding: 1px 3px;

              &:hover {
                background-color: #F6F6F6;
              }
            }
          }
        }

        pre {
          .pre-wrap;
          font-size: 90%;
        }
      }
    }
  }

  .ui-icon-gripsmall-diagonal-se {
    background: url('@{img_base}/resize-grip.png') no-repeat top left;
  }
}

.issue-state {
  @issue-state-height: 26px;

  font-weight: bold;
  line-height: @issue-state-height;
  margin-bottom: 2em;
  min-height: @issue-state-height;
  padding: 0.6em;
  .transition(0.1s linear all);

  input, .back-to-issue-summary {
    /*
     * This keeps a consistency with the browser. By default, Chrome uses
     * a margin of 2px, and changing it to 0 actually makes things look
     * off-center.
     */
    margin: 2px 2px 2px 0.2em;
    vertical-align: middle;
  }

  .issue-container {
    position: relative;
  }

  .rb-icon {
    margin: 0 0.2em;
  }

  &.dropped {
    background: @issue-discarded-bg;
    border: 1px @issue-discarded-border-color solid;

    .back-to-issue-summary, .back-to-issue-summary:visited {
      color: @issue-discarded-link-color;
    }
  }

  &.open {
    background: @issue-opened-bg;
    border: 1px @issue-opened-border-color solid;

    .back-to-issue-summary, .back-to-issue-summary:visited {
      color: @issue-opened-link-color;
    }
  }

  &.resolved {
    background: @issue-resolved-bg;
    border: 1px @issue-resolved-border-color solid;

    .back-to-issue-summary, .back-to-issue-summary:visited {
      color: @issue-resolved-link-color;
    }
  }

  .back-to-issue-summary {
    font-size: 13px;
    font-weight: normal;
    text-decoration: none;
    padding: 0 0.5em;
    position: absolute;
    right: 0;
    height: 24px;
    line-height: 24px;

    &:hover {
      text-decoration: underline;
    }
  }

  .issue-message {
    margin-right: 0.5em;
    vertical-align: middle;
  }

  .on-mobile-medium-screen-720({
    .back-to-issue-summary {
      display: none;
    }

    .issue-actions {
      display: block;
      margin-top: 0.5em;

      input:first-child {
        margin-left: 0;
      }
    }

    .issue-details {
      display: inline-block;
      overflow: hidden;
      vertical-align: top;
    }
  });
}


/****************************************************************************
 * Banners
 ****************************************************************************/
#discard-banner,
#submitted-banner {
  background: #E0E0E0;
  border: 1px #808080 solid;
  .border-radius(@box-border-radius);
  .box-shadow(@box-shadow);
}

#draft-banner {
  border-top: 0;
  border-left: 0;
  border-right: 0;
  .box-shadow(@box-shadow);
  margin-top: -@page-container-padding;
  margin-left: -@page-container-padding;
  margin-right: -@page-container-padding;
  margin-bottom: @page-container-padding;
  padding: @page-container-padding;
}

#draft-banner,
#discard-banner,
#submitted-banner {
  .on-mobile-medium-screen-720({
    .banner-actions {
      margin-bottom: 2em;
    }
  });

  p label {
    .inline-editor-label();
  }

  &>p {
    margin: 1em 0 0 0;
  }
}

#review-banner {
  padding-bottom: 4em;

  .banner {
    border-left: 0;
    border-right: 0;
    border-top: 0;
    left: 0;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: @z-index-banner;
    .box-shadow(@box-shadow);
  }
}


/****************************************************************************
 * Tooltips
 ****************************************************************************/
.tooltip {
  background-color: #fef6b3;
  border: 1px #a58600 solid;
  padding: 4px;
  position: absolute;
  max-width: 60em;

  &.comments {
    border: 1px black solid;
    border-bottom: 0;
    padding: 0;

    > ul {
      list-style: none;
      margin: 0;
      padding: 0;

      > li {
        background-color: #a1c0e3;
        border-bottom: 1px #5170b3 solid;
        margin: 0;
        padding: 5px;

        &.draft {
          background-color: #aceb6f;
          border-bottom: 1px black solid;
        }

        div {
          &.reviewer {
            font-weight: bold;
          }
        }

        pre {
          .pre-wrap;
          font-size: 8pt;
          margin: 0;
          padding: 0;
        }
      }
    }
  }
}


/****************************************************************************
 * Bubbles
 ****************************************************************************/
.bubble {
  background-color: white;
  border: 1px black solid;
  font-size: 10pt;
  font-weight: bold;
  padding: 6px;
  position: absolute;
  white-space: nowrap;
  z-index: @z-index-dialog;
  .border-radius(8px);
}


/****************************************************************************
 * Issue Summary
 ****************************************************************************/

.issue-table-wrapper {
  clear: both;
}

#issue-summary-table {
  border-spacing: 0;
  width: 100%;

  .on-mobile-medium-screen-720({
    border: 1px @dark-yellow solid;
  });

  tr {
    &:last-child td {
      &.status {
        .border-radius(0 0 @box-border-radius 0);
      }

      &.summary-table-description {
        .border-radius(0 0 0 @box-border-radius);
      }
    }

    td {
      border-width: 0 0 1px 0;
      border-style: solid;
      padding: 5px 8px;
      vertical-align: top;

      a {
        color: #0000CC;
        text-decoration: none;
      }

      .on-mobile-medium-screen-720({
        border: 0;
        display: block;
      });
    }

    &.hidden {
      display: none;
    }
  }

  thead {
    .on-mobile-medium-screen-720({
      display: none !important;
    });

    th {
      background: #E9E9E9;
      border-color: #999;
      border-style: solid;
      border-width: 1px 0;
      cursor: pointer;
      height: 21px;
      padding: 2px 8px;
      text-align: left;
      white-space: nowrap;

      &:hover {
        background: #F9F9F9;
      }
    }

    .description-header {
      border-left-width: 1px;
      .border-radius(@box-border-radius 0 0 0);
    }

    .status-header {
      border-right-width: 1px;
      .border-radius(0 @box-border-radius 0 0);
    }
  }

  .issue {
    .status {
      border-right-width: 1px;
    }

    .summary-table-description {
      border-left-width: 1px;
      width: 100%;
    }

    &.open {
      td {
        background-color: #FDF4A4;
        border-color: @dark-yellow;
      }
    }

    &.dropped {
      td {
        background-color: @light-grey;
        border-color: #AAA;
      }
    }

    &.resolved {
      td {
        background-color: #FFF;
        border-color: #AAA;
      }
    }

    &:hover td {
      background-color: #D4E0F3;
      border-color: @dark-blue;
    }

    .summary-anchor {
      color: #000;
      display: block;
      overflow: hidden;
      text-decoration: none;
    }

    .on-mobile-medium-screen-720({
      &:last-child .status {
        border-bottom: 0;
      }

      .status {
        border-bottom: 1px transparent solid;
      }

      .status, .summary-table-description {
        border-left: 0;
        border-right: 0;
        width: auto;
      }
    });
  }

  .no-issues {
    td {
        background-color: #FFF;
        border-color: #999;
        border-width: 1px;
    }
  }

  .status {
    text-transform: capitalize;
  }

  .comment-id, .last-updated, .reviewer, .status {
    white-space: nowrap;

    .on-mobile-medium-screen-720({
      white-space: normal;
    });
  }
}

#issue-summary {
  .header {
    padding-bottom: 0;
    position: relative;

    .counters {
      position: absolute;
      bottom: 0;
      right: @box-padding;

      .on-mobile-medium-screen-720({
        position: initial;
      });

      .counter {
        margin-left: 4px;

        &.total {
          label, span {
            font-weight: bold;
          }
        }

        label {
          color: black;
          font-weight: normal;
          margin-right: 3px;
        }
      }
    }

    .filters {
      margin: 1em 0 1.5em 0;

      .filter-wrapper {
        display: inline;
        margin: 0 0.5em;

        .on-mobile-medium-screen-720({
          display: block;
          margin: 1em 0.5em;
        });

        &:first-child {
          margin-left: 0;
        }

        select {
          margin-left: 0.2em;
        }
      }
    }
  }
}


/****************************************************************************
 * Rich text
 ****************************************************************************/

/*
 * Note that there's similar styling code in
 * reviewboard/notifications/templatetags/markdown_email.py. If you make
 * substantial changes here, you may also want to make changes there.
 */

.rich-text {
  .hide-br() {
    br {
      display: none;
    }
  }

  .show-br() {
    br {
      display: block;
    }
  }

  line-height: @textarea-line-height;
  .box-sizing(border-box);

  * {
    margin: 0;
    padding: 0;

    line-height: inherit;
    text-rendering: inherit;
    white-space: normal;

    .show-br();
  }

  h1, h2, h3, h4, h5, h6 {
    font-size: 100%;
  }

  p {
    white-space: inherit;

    /* Don't show both the <br> and the blank line. */
    .hide-br();
  }

  ul, ol {
    line-height: 0;
    margin: 0;
    padding: 0;

    p {
      /*
       * <p> tags in a list do not preserve whitespace, since there's
       * mandatory leading whitespace before the content.
       */
      .show-br();
    }

    ul, ol {
      margin-left: 2ch;
    }
  }

  ol {
    /*
     * We want to keep wrapped text within the confines of the list item. So:
     *
     * 1. This is long text that
     *    wraps like this.
     *
     * Instead of:
     *
     * 1. This is long text that
     * wraps like this.
     *
     * To do this, we need to use display: table and display: table-cell.
     * However, that loses item counter rendering, so we have to do counters
     * ourselves. In combination with StyledOListBlockProcessor in
     * reviewboard/reviews/markdown_extensions.py, this maintains compatibility
     * with the start= attribute.
     */
    counter-reset: li;
    display: table;
    list-style-position: inside;

    > li {
      counter-increment: li;
      display: table;

      &::before {
        content: counter(li) ". ";
        padding-right: 1ch;
        display: table-cell;
        text-align: right;
      }
    }
  }

  ul {
    list-style-position: outside;
    list-style: disc;
    margin-left: 2ch;
  }

  li {
    line-height: @textarea-line-height;

    ~ li:last-child {
      p:last-child {
        margin-bottom: 0;
      }
    }

    p {
      margin-bottom: @textarea-line-height;

      /*
       * If the list item ends up with a sole <p>, just remove the margins.
       * Depending on neighboring elements, Python Markdown will sometimes
       * create list items this way.
       */
      &:first-child:last-child {
        margin: 0;
      }
    }
  }

  table {
    th, td {
      border-bottom: 1px solid #bbb;
      padding: 0.2em 1em;
    }
  }

  code {
    color: #4444cc;
  }

  pre {
    .pre-wrap;
    font-size: inherit;
    margin-left: 2.5em;

    * {
      .pre-wrap;
    }
  }

  blockquote {
    border-left: 1px solid #bbb;
    padding-left: 1em;
    margin-left: 0.5em;
  }

  hr {
    border: 1px solid #ddd;
  }
}


/****************************************************************************
 * "Update Diff" dialog
 ****************************************************************************/

.update-diff {
  width: 60em;
  height: 16em;

  #prompt-for-basedir,
  #prompt-for-diff,
  #prompt-for-parent-diff,
  #processing-diff,
  #uploading-diffs,
  #error-indicator {
    display: none;
  }

  #error-contents,
  #parent-diff-error-contents {
    position: relative;
    margin: 0 5em;
    line-height: 12pt;
    margin-bottom: 1em;

    img {
      margin-right: 5px;
      vertical-align: sub;
    }
  }

  #processing-diff,
  #uploading-diffs {
    background: url('@{img_base}/spinner.gif') center center no-repeat;
  }

  .input {
    text-align: center;
    vertical-align: middle;
    height: 16em;
    line-height: 16em;
    margin: 2em 2em 6em 2em;
    border: 1px solid @grey;
    .border-radius(@box-border-radius);
    background-color: lighten(@light-grey, 10%);
    position: relative;

    .startover {
      position: absolute;
      bottom: 0;
      right: 5px;
      line-height: 14pt;
    }
  }

  .drag-hover {
    border: 1px solid darken(@grey, 4%);
    .box-shadow(inset @box-shadow);
  }
}


// vim: set et ts=2 sw=2:
